const mongoose = require('../common/db');

const slideshow = new mongoose.Schema({
  name: String,
  imagesList: Array
});

slideshow.statics.findByname = function (name, callback) {
  this.findOne({ name: name }, callback);
};

const slideshowModel = mongoose.model("slideshow", slideshow);
module.exports = slideshowModel;